package com.lzh.edu.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.lzh.commonutils.CourseInfo;
import com.lzh.edu.entity.Course;
import com.baomidou.mybatisplus.extension.service.IService;
import com.lzh.edu.query.CourseQuery;
import com.lzh.edu.vo.CourseInfoVo;
import com.lzh.edu.vo.course.CourseFrontVo;
import com.lzh.edu.vo.course.CoursePublishVo;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 课程 服务类
 * </p>
 *
 * @author lizuhu
 * @since 2021-04-24
 */
public interface CourseService extends IService<Course> {

    String saveCourseInfo(CourseInfoVo courseInfoVo);

    CourseInfoVo getCourseInfo(String courseId);

    void updateCourseInfo(CourseInfoVo courseInfoVo);

    CoursePublishVo getPublishCourse(String courseId);

    Boolean publishCourse(String courseId);

    void pageQuery(Page<Course> pageParam, CourseQuery courseQuery);

    Boolean removeCourseById(String id);

    List<Course> getcourseByLimit();

    List<Course> selectListByTeacherId(String id);

    void pageList(Page<Course> coursePage);
    /**
     * 获取课程信息
     * @param id
     * @return
     */
    CourseFrontVo selectInfoWebById(String id);

    /**
     * 更新课程浏览数
     * @param id
     */
    void updatePageViewCount(String id);

    CourseInfo getCourseByOrder(String id);
}
